package com.nhtrinh.game;

import android.os.Bundle;
import android.support.v4.app.FragmentActivity;
import android.support.v4.view.ViewPager;
import android.view.Window;

import com.nhtrinh.lib.CirclePageIndicator;
import com.nhtrinh.lib.PageIndicator;

public class HelpActivity extends FragmentActivity {

	HelpFragmentAdapter mAdapter;
    ViewPager mPager;
    PageIndicator mIndicator;
	
	@Override
    protected void onCreate(Bundle savedInstanceState) {
		requestWindowFeature(Window.FEATURE_NO_TITLE);
        super.onCreate(savedInstanceState);
        setContentView(R.layout.simple_circles);

        String[] arrContent = getResources().getStringArray(R.array.help_content);
        
        mAdapter = new HelpFragmentAdapter(getSupportFragmentManager(), arrContent );

        mPager = (ViewPager)findViewById(R.id.pager);
        mPager.setAdapter(mAdapter);

        CirclePageIndicator indicator = (CirclePageIndicator)findViewById(R.id.indicator);
        mIndicator = indicator;
        indicator.setViewPager(mPager);

        final float density = getResources().getDisplayMetrics().density;
        indicator.setBackgroundColor(0xFFCCCCCC);
        indicator.setRadius(10 * density);
        indicator.setPageColor(0x880000FF);
        indicator.setFillColor(0xFF888888);
        indicator.setStrokeColor(0xFF000000);
        indicator.setStrokeWidth(2 * density);
    }

	
}
